package com.movie.view;

import android.content.Context;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.view.View;
import android.view.animation.Transformation;
import android.widget.Gallery;

public class UGallery extends Gallery {

	public UGallery(Context context, AttributeSet attrs, int defStyle) {
		super(context, attrs, defStyle);
	}

	public UGallery(Context context, AttributeSet attrs) {
		super(context, attrs);
	}

	public UGallery(Context context) {
		super(context);
	}

	@Override
	protected boolean getChildStaticTransformation(View child, Transformation t) {
		super.getChildStaticTransformation(child, t);
		return true;
	}
	boolean flag = true;

	@Override
	protected void onLayout(boolean changed, int l, int t, int r, int b) {
		if (flag) {
			super.onLayout(changed, l, t, r, b);
			flag = false;
		}
	}

	@Override
	public boolean onScroll(MotionEvent e1, MotionEvent e2, float distanceX,
			float distanceY) {
		super.onScroll(e1, e2, distanceX, distanceY);
		return true;
	}

	@Override
	public boolean onTouchEvent(MotionEvent event) {
		super.onTouchEvent(event);
		return true;
	}

}
